export function reqApi(config = {
	url: "/ssj",
	data:{},
	method:'get',
	header:{
		'Content-Type':"application/json"
	}
}) {
	return new Promise((resolve, reject) => {
		// const baseUrl = 'https://formal.api.yxytcar.cn/v2'
		const baseUrl = 'https://formal.api.yxytcar.cn/v1'
		const {
			url,
			data,
			method,
			header
		} = config

		uni.request({
			url: baseUrl + url, //仅为示例，并非真实接口地址。
			method,
			data,
			header: {
				'custom-header': 'hello' //自定义请求头信息
			},
			success: (res) => {
				resolve(res)
			},
			fail() {
				reject(res)
			}
		});
	})
}